import 'package:flutter/material.dart';

import 'package:get/get.dart';
import 'package:getx_learn/app/common/widgets/widgets.dart';
import 'package:getx_learn/app/routes/app_pages.dart';

import '../controllers/compose_demo_controller.dart';

class ComposeDemoView extends GetView<ComposeDemoController> {
  const ComposeDemoView({Key? key}) : super(key: key);
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: getAppBar(context: context, title: "组件"),
      body: ListView(
        children: [
            ListTile(
              title: Text("组件-Snackbar"),
              subtitle: Text("Snackbar的展示"),
              onTap: (){
                Get.toNamed(Routes.SNACKBAR_DEMO);
              },
            ),
          Divider(),

          ListTile(
            title: Text("组件-Dialog"),
            subtitle: Text("Dialog的展示"),
            onTap: (){
              Get.toNamed(Routes.DIALOG_DEMO);
            },
          ),
          Divider(),


          ListTile(
            title: Text("组件-BottomSheet"),
            subtitle: Text("BottomSheet的展示"),
            onTap: (){
              Get.toNamed(Routes.BOTTOM_SHEET_DEMO);
            },
          ),
          Divider(),

        ],
      ),
    );
  }
}
